package com.ftg.learn.chapter02.java.inner;

/**
 * 测试 内部类 -
 *
 * @author kangjx
 * @version 1.0
 * @date 2023/12/21 上午9:13
 */
public class TestInner {

    public static void main(String[] args) {
        IShuXueInner iShuXueInner = new IShuXueInner() {
            @Override
            public int jiafa(int x, int y) {
                return x + y + 30;
            }

            @Override
            public int jianfa(int x, int y) {
                return x - y - 2;
            }
        };

        IShuXueInner iShuXueInner1 = new IShuXueInner() {
            @Override
            public int jiafa(int x, int y) {
                return x + y + 40;
            }

            @Override
            public int jianfa(int x, int y) {
                return x - y - 3;
            }
        };

        iShuXueInner1.jiafa(2,3);
    }

}
